//
//  FCBaseVC.m
//  FundChain
//
//  Created by 肖浩然的mac on 2018/2/6.
//  Copyright © 2018年 RUIXIN. All rights reserved.
//

#import "FCBaseVC.h"

@interface FCBaseVC ()

@end

@implementation FCBaseVC

-(instancetype)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil{
    
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}



- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor whiteColor];
}

-(void)setShowBackItem:(BOOL)showBackItem{
    if (showBackItem) {
        UIButton *back = [UIButton buttonWithType:(UIButtonTypeCustom)];
        back.frame = CGRectMake(10, 0, 23, 20);
        UIBarButtonItem *left = [[UIBarButtonItem alloc]initWithCustomView:back];
        [back setImage:[UIImage imageNamed:@"icon_back_black"] forState:(UIControlStateNormal)];
        [back addTarget:self action:@selector(backAction) forControlEvents:(UIControlEventTouchUpInside)];
        self.navigationItem.leftBarButtonItem = left;
        
    }
}
-(void)backAction{
    [self.navigationController popViewControllerAnimated:NO];
}

- (UIStatusBarStyle)preferredStatusBarStyle
{
    return UIStatusBarStyleLightContent;
    
}
@end
